.login-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
  padding: 20px;
  position: relative;
  overflow: hidden;
}

.login-page::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  transform: rotate(30deg);
}

.login-container {
  display: flex;
  width: 100%;
  max-width: 1000px;
  height: 620px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 1;
  contain: layout style paint; /* 优化渲染性能 */
}

.login-illustration {
  flex: 1;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px;
  color: white;
  position: relative;
  overflow: hidden;
}

.login-illustration::before {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
}

.login-illustration::after {
  content: "";
  position: absolute;
  bottom: -80px;
  left: -30px;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
}

.seeker-image {
  width: 240px;
  height: auto;
  margin-bottom: 30px;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
  animation: float 3s ease-in-out infinite;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
  padding: 15px;
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-15px);
  }
  100% {
    transform: translateY(0px);
  }
}

.illustration-title {
  color: white;
  text-align: center;
  margin-bottom: 16px;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  font-size: var(--font-size-xxl);
}

.illustration-subtitle {
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  font-size: var(--font-size-md);
  max-width: 300px;
  line-height: 1.6;
}

.login-form-section {
  flex: 1;
  background: white;
  display: flex;
  flex-direction: column;
  padding: 50px 50px;
  position: relative;
  overflow: visible; /* 确保内容不会被裁剪 */
  z-index: 2; /* 确保表单区域在其他元素之上 */
}

.login-header {
  text-align: center;
  margin-bottom: 40px;
}

.login-header h3 {
  color: var(--color-text-1);
  font-weight: 700;
  margin-bottom: 10px;
  font-size: 28px;
}

.login-header p {
  color: var(--color-text-3);
  font-size: var(--font-size-sm);
  margin: 0;
}

/* Tabs 样式 */
.login-tabs {
  margin-bottom: 30px;
}

.arco-tabs {
  border: none;
}

.arco-tabs-nav {
  border: none;
  margin-bottom: 0;
  display: flex;
  justify-content: center;
  position: relative;
}

.arco-tabs-nav::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--color-border-2);
}

.arco-tabs-tab {
  font-size: var(--font-size-lg);
  padding: 12px 0;
  margin: 0 25px;
  cursor: pointer;
  position: relative;
  color: var(--color-text-2);
  transition: color 0.3s ease;
  font-weight: 500;
  user-select: none;
}

.arco-tabs-tab:hover {
  color: var(--color-text-1);
}

.arco-tabs-tab-active {
  font-weight: 600;
  position: relative;
  color: var(--color-primary);
}

.arco-tabs-tab-active::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--color-primary);
  border-radius: 3px;
}

/* 表单区域 */
.login-form-container {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 250px;
  perspective: 1000px;
  overflow: visible;
  z-index: 3;
}

/* 自定义输入框样式 */
.custom-input-wrapper {
  position: relative;
  margin-bottom: 24px;
}

.custom-input-wrapper label {
  display: block;
  margin-bottom: 8px;
  font-size: var(--font-size-md);
  color: var(--color-text-2);
  font-weight: 500;
}

.custom-input {
  width: 100%;
  height: 52px;
  padding: 0 20px 0 52px;
  border: 2px solid var(--color-border-2);
  border-radius: 12px;
  font-size: var(--font-size-md);
  color: var(--color-text-1);
  background-color: #ffffff;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  outline: none;
}

.custom-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 6px 16px rgba(22, 93, 255, 0.2);
}

.custom-input:hover:not(:focus) {
  border-color: var(--color-primary);
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.15);
}

.custom-input::placeholder {
  color: var(--color-text-3);
}

.custom-input-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-3);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 自定义短信验证码输入框样式 */
.sms-code-wrapper {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
}

.sms-code-input-wrapper {
  position: relative;
  flex: 1;
}

.sms-code-input {
  width: 100%;
  height: 52px;
  padding: 0 20px 0 52px;
  border: 2px solid var(--color-border-2);
  border-radius: 12px;
  font-size: var(--font-size-md);
  color: var(--color-text-1);
  background-color: #ffffff;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  outline: none;
}

.sms-code-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 6px 16px rgba(22, 93, 255, 0.2);
}

.sms-code-input:hover:not(:focus) {
  border-color: var(--color-primary);
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.15);
}

.sms-code-input::placeholder {
  color: var(--color-text-3);
}

.sms-code-input-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-3);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 自定义按钮样式 */
.custom-button {
  height: 52px;
  border-radius: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-size: var(--font-size-md);
  position: relative;
  overflow: hidden;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.custom-button.primary {
  background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.3);
}

.custom-button.primary:hover {
  background: linear-gradient(90deg, var(--color-primary-hover) 0%, #5a8fff 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(22, 93, 255, 0.4);
}

.custom-button.primary:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.3);
}

.custom-button.secondary {
  background: transparent;
  border: 1px solid var(--color-border-2);
  color: var(--color-text-2);
  margin-top: 12px;
}

.custom-button.secondary:hover {
  background: var(--color-fill-1);
  color: var(--color-text-1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.custom-button.secondary:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.custom-button.sms-code {
  width: auto;
  min-width: 120px;
  background-color: var(--color-primary);
  color: white;
  box-shadow: 0 2px 6px rgba(22, 93, 255, 0.2);
}

.custom-button.sms-code:hover:not(.disabled) {
  background-color: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(22, 93, 255, 0.3);
}

.custom-button.sms-code:active:not(.disabled) {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(22, 93, 255, 0.2);
}

.custom-button.sms-code.disabled {
  background-color: #e2e8f0;
  color: #94a3b8;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* 短信验证码操作区域 */
.sms-code-actions {
  margin-top: 0;
  margin-bottom: 24px;
  display: flex;
  justify-content: flex-end;
  height: 52px;
}

/* 设置密码表单样式 */
.password-form-wrapper {
  width: 100%;
}

.password-tip {
  display: block;
  margin-bottom: 24px;
  color: var(--color-text-2);
  font-size: var(--font-size-md);
  text-align: center;
}

.set-password-button {
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
  border: none;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  color: white;
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.3);
  font-size: var(--font-size-md);
  position: relative;
  overflow: hidden;
}

.set-password-button:hover {
  background: linear-gradient(90deg, var(--color-primary-hover) 0%, #5a8fff 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(22, 93, 255, 0.4);
}

.set-password-button:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(22, 93, 255, 0.3);
}

/* 跳过设置密码按钮样式 */
.skip-password-button {
  height: 52px;
  border-radius: 12px;
  background: transparent;
  border: 1px solid var(--color-border-2);
  font-weight: 500;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  color: var(--color-text-2);
  font-size: var(--font-size-md);
  position: relative;
  overflow: hidden;
  margin-top: 12px;
}

.skip-password-button:hover {
  background: var(--color-fill-1);
  color: var(--color-text-1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.skip-password-button:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* 社交登录 */
.social-login {
  text-align: center;
  margin-top: 10px;
  padding: 20px 0; /* 为社交登录区域添加内边距 */
  position: relative; /* 为内部元素提供定位上下文 */
  z-index: 1; /* 确保社交登录区域在其他元素之上 */
  clear: both; /* 确保社交登录区域不会与其他浮动元素重叠 */
  display: block; /* 确保社交登录区域作为块级元素显示 */
}

.social-login-text {
  display: block;
  margin-bottom: 10px;
  color: var(--color-text-3);
  font-size: var(--font-size-sm);
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 15px;
  align-items: center; /* 确保子元素垂直居中 */
  min-height: 40px; /* 确保容器有足够的高度来显示按钮 */
}

.social-icon-button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #e2e8f0;
  background-color: #f8f9fa;
  color: var(--color-text-2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  padding: 0;
  cursor: pointer;
  overflow: hidden; /* 确保内容不超出按钮边界 */
  position: relative; /* 为内部元素提供定位上下文 */
  flex-shrink: 0; /* 防止按钮在flex容器中被压缩 */
  line-height: 1; /* 确保行高不会影响图标居中 */
  box-sizing: border-box; /* 确保边框包含在宽高内 */
  aspect-ratio: 1; /* 确保按钮始终保持正方形 */
  transform: translateZ(0); /* 触发硬件加速，确保按钮正确渲染 */
  backface-visibility: hidden; /* 防止3D变换时的渲染问题 */
  perspective: 1000px; /* 为3D变换提供透视 */
  will-change: transform; /* 提示浏览器该元素将要发生变换 */
  -webkit-transform: translateZ(0); /* Safari兼容性 */
  -webkit-backface-visibility: hidden; /* Safari兼容性 */
  -webkit-perspective: 1000px; /* Safari兼容性 */
  -webkit-will-change: transform; /* Safari兼容性 */
  -webkit-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Safari兼容性 */
  -moz-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Firefox兼容性 */
  -o-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Opera兼容性 */
}

.social-icon-button:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 4px 8px rgba(22, 93, 255, 0.2);
  z-index: 2; /* 确保悬停时按钮在其他元素之上 */
  will-change: transform; /* 提示浏览器该元素将要发生变换 */
  -webkit-transform: translateY(-3px) scale(1.1); /* Safari兼容性 */
  -webkit-box-shadow: 0 4px 8px rgba(22, 93, 255, 0.2); /* Safari兼容性 */
  -moz-transform: translateY(-3px) scale(1.1); /* Firefox兼容性 */
  -o-transform: translateY(-3px) scale(1.1); /* Opera兼容性 */
}

.social-icon-button:active {
  transform: translateY(0) scale(1);
  transition: transform 0.1s ease; /* 为激活状态添加过渡效果 */
  will-change: transform; /* 提示浏览器该元素将要发生变换 */
  -webkit-transform: translateY(0) scale(1); /* Safari兼容性 */
  -moz-transform: translateY(0) scale(1); /* Firefox兼容性 */
  -o-transform: translateY(0) scale(1); /* Opera兼容性 */
  -webkit-transition: transform 0.1s ease; /* Safari兼容性 */
  -moz-transition: transform 0.1s ease; /* Firefox兼容性 */
  -o-transition: transform 0.1s ease; /* Opera兼容性 */
}

.social-icon-button .arco-icon {
  width: 20px;
  height: 20px;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0; /* 防止图标在flex布局中被压缩 */
  flex-grow: 0; /* 防止图标在flex布局中被拉伸 */
  flex-basis: auto; /* 确保图标大小基于内容 */
  max-width: 100%; /* 确保图标不会超出按钮边界 */
  max-height: 100%; /* 确保图标不会超出按钮边界 */
  object-fit: contain; /* 确保图标在容器内正确显示 */
  transform: translateZ(0); /* 触发硬件加速，确保图标正确渲染 */
  backface-visibility: hidden; /* 防止3D变换时的渲染问题 */
  perspective: 1000px; /* 为3D变换提供透视 */
  -webkit-transform: translateZ(0); /* Safari兼容性 */
  -webkit-backface-visibility: hidden; /* Safari兼容性 */
  -webkit-perspective: 1000px; /* Safari兼容性 */
  /* 调试样式 - 可以帮助识别图标显示问题 */
  /* background-color: rgba(255, 0, 0, 0.1); */
  /* border: 1px solid red; */
}

/* 动画效果 */
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* 响应式设计 */
@media (max-width: 992px) {
  .login-container {
    max-width: 90%;
    height: auto;
    min-height: 500px;
  }
}

@media (max-width: 768px) {
  .login-container {
    flex-direction: column;
    max-width: 95%;
    margin: 10px;
    height: auto;
    border-radius: 16px;
  }
  
  .login-illustration {
    padding: 30px 20px;
    min-height: 250px;
  }
  
  .seeker-image {
    width: 150px;
  }
  
  .login-form-section {
    padding: 30px 20px;
  }
  
  .social-icons {
    gap: 12px;
    min-height: 36px;
  }
  
  .social-icon-button {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }
  
  .social-icon-button .arco-icon {
    width: 18px;
    height: 18px;
    font-size: 18px;

    transform: translateZ(0);
    -webkit-transform: translateZ(0); /* Safari兼容性 */
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden; /* Safari兼容性 */
    perspective: 1000px;
    -webkit-perspective: 1000px; /* Safari兼容性 */
  }
  
  .login-header {
    margin-bottom: 30px;
  }
  
  .login-header h3 {
    font-size: 24px;
  }
}

@media (max-width: 480px) {
  .login-container {
    margin: 5px;
    border-radius: 12px;
  }
  
  .login-form-section {
    padding: 25px 15px;
  }
  
  .arco-tabs-tab {
    margin: 0 15px;
    font-size: var(--font-size-md);
  }
  
  .sms-code-wrapper {
    flex-direction: column;
  }
  
  .sms-code-button {
    min-width: auto;
  }
  
  .login-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  
  .arco-input-wrapper {
    height: 48px;
  }
  
  .sms-code-button,
  .login-button {
    height: 48px;
  }
}

/* 错误信息样式 */
.form-error {
  background-color: #fff2f0;
  border: 1px solid #ffccc7;
  border-radius: 6px;
  padding: 12px 16px;
  margin-bottom: 16px;
  color: #ff4d4f;
  font-size: 14px;
  line-height: 1.5;
  display: flex;
  align-items: center;
}

.form-error::before {
  content: "⚠";
  margin-right: 8px;
  font-size: 16px;
}

.input-error {
  color: #ff4d4f;
  font-size: 12px;
  line-height: 1.4;
  margin-top: 4px;
  margin-bottom: 12px;
  padding-left: 4px;
  display: flex;
  align-items: center;
}

.input-error::before {
  content: "•";
  margin-right: 4px;
  font-size: 14px;
}

/* 输入框错误状态样式 */
.custom-input.error {
  border-color: #ff4d4f !important;
  box-shadow: 0 0 0 2px rgba(255, 77, 79, 0.2) !important;
}

.custom-input.error:focus {
  border-color: #ff4d4f !important;
  box-shadow: 0 0 0 2px rgba(255, 77, 79, 0.3) !important;
}

/* 按钮禁用状态样式 */
.custom-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

.custom-button.primary:disabled {
  background-color: #d9d9d9;
  border-color: #d9d9d9;
  color: rgba(0, 0, 0, 0.25);
}

.custom-button.secondary:disabled {
  background-color: #f5f5f5;
  border-color: #d9d9d9;
  color: rgba(0, 0, 0, 0.25);
}

/* 响应式设计 - 移动端错误信息样式优化 */
@media (max-width: 768px) {
  .form-error {
    padding: 10px 12px;
    font-size: 13px;
    margin-bottom: 12px;
  }
  
  .input-error {
    font-size: 11px;
    margin-top: 3px;
    margin-bottom: 10px;
  }
}

/* 暗色主题支持 */
@media (prefers-color-scheme: dark) {
  .form-error {
    background-color: #2a1215;
    border-color: #58181c;
    color: #ff7875;
  }
  
  .input-error {
    color: #ff7875;
  }
  
  .custom-input.error {
    border-color: #ff7875 !important;
    box-shadow: 0 0 0 2px rgba(255, 120, 117, 0.2) !important;
  }
  
  .custom-input.error:focus {
    border-color: #ff7875 !important;
    box-shadow: 0 0 0 2px rgba(255, 120, 117, 0.3) !important;
  }
}